package com.quarkus.cloud.repository;

import com.quarkus.cloud.domain.entity.User;
import io.quarkus.hibernate.reactive.panache.PanacheRepository;
import io.quarkus.panache.common.Page;
import io.quarkus.panache.common.Sort;
import jakarta.enterprise.context.ApplicationScoped;

import java.util.Map;

/**
 * @author zhuhb-a
 */
@ApplicationScoped
public class UserRepository implements PanacheRepository<User> {

    public Page page(Map<String, Object> params, Page page) {
        return findAll(Sort.by("id")).page(page).page();
    }
}
